import { reactive } from "vue";
import type { FormRules } from "element-plus";

/** 自定义表单规则校验 */
export const formRules = reactive(<FormRules>{
	name: [{ required: true, message: "报警名称为必填项", trigger: "blur" }],
	code: [{ required: true, message: "报警编码为必填项", trigger: "blur" }],
	type: [{ required: true, message: "报警类型为必填项", trigger: "blur" }],
	interval: [{ required: true, message: "时间间隔为必填项", trigger: "blur" }],
	roleList: [{ required: true, message: "推送角色为必填项", trigger: "change" }],
});
